package com.yxuan.springboot.controller;

import com.yxuan.springboot.service.OutRecordsService;
import com.yxuan.springboot.util.Result;
import io.swagger.annotations.Api;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.stereotype.Controller;
import com.yxuan.springboot.model.OutRecords;
import org.springframework.web.bind.annotation.ResponseBody;

/**
 * 
 * @author zchao
 *   OutRecords控制器
 * @date 2024-05-24 20:58:16
 */
@Controller
@Api(tags = "提现记录表")
@RequestMapping(value = "/outrecords", method = {RequestMethod.POST,RequestMethod.GET})
public class OutRecordsController extends BaseController<OutRecords>{


    @Autowired
    private OutRecordsService outRecordsService;
    /*
    * 查看提现金额
    * */
    @ResponseBody
    @RequestMapping("/getOutAmount")
    public Result getOutAmount(String agentId) throws Exception {
        return outRecordsService.getOutAmount(agentId);
    }

    /*
     * 添加提现记录
     * */
    @ResponseBody
    @RequestMapping("/setOutRecord")
    public Result setOutRecord(String agentId) throws Exception {
        return outRecordsService.setOutRecord(agentId);
    }




}
